//app.js
App({
  onLaunch: function () {
    let sysinfo = wx.getSystemInfoSync();
    this.globalData.scale = sysinfo.windowWidth / 750;
    this.globalData.scaleH = sysinfo.windowHeight / 1334;

  },
  globalData: {
    access_token: "24.eb9fc90948c06cb698f21879be647a3d.2592000.1575195624.282335-15710368",
    scale:0,
    scaleH:0
  },
  getStyle(w, h, l, t, s, sh) {
    let width = w * s;
    let height = h * sh;
    let left = l * s;
    let top = t * sh;
    return [width, height, left, top];
  },
  gw(w){
    return this.gI(w*this.globalData.scale)
  },
  gh(h){
    return this.gI(h * this.globalData.scale)
  },
  gI(num){
    return Math.floor(num);
  },
})